**Replication File for "Gendered Expectations: Do Voters Reward Women for Supporting Women's Interests?" British Journal of Political Science
**Authors: Nichole Bauer, Anna Gunderson, Jeong Kim, Elizabeth Lane, Belinda Davis, Kathleen Searles


**Content Analysis
*Figure 1
**use: "H:\My Drive\Research\Bauer et al\analyzer data downloaded_bauer et al_feb23.csv", clear
gen time_date = date(time, "MDY")
format time_date %td

*value is number of seconds represented by women candidate coverage, as indicated by actual phrase

tsset time_date
line value time_date
gen year= year(time_date)
line value year
save "H:\My Drive\Research\Bauer et al\analyzer data downloaded_bauer et al_feb23.dta"

collapse (mean) value, by(year)
save "H:\My Drive\Research\Bauer et al\collapsed data.dta"
graph twoway line value year 
*dots==seconds of coverage by excerpt aggregated by month
*lines==average no of sec of coverage of women candidates by year 

sum value details
egen modvalue = mode(value)
*mode 0
*looking at it by outlet on analyzer:https://tvnews.stanford.edu/?dataVersion=v1&data=eyJvcHRpb25zIjp7ImFnZ3JlZ2F0ZSI6Im1vbnRoIn0sInF1ZXJpZXMiOlt7ImNvbG9yIjoiI0YyOEUyQiIsInRleHQiOiJ0ZXh0PSBcIndvbWVuIGNhbmRpZGF0ZXNcIiJ9LHsiY29sb3IiOiIjNEU3OUE3IiwidGV4dCI6InRleHQ9IFwid29tZW4gY2FuZGlkYXRlc1wiIEFORCBjaGFubmVsPVwiQ05OXCIifSx7ImNvbG9yIjoiI0UxNTc1OSIsInRleHQiOiJ0ZXh0PSBcIndvbWVuIGNhbmRpZGF0ZXNcIiBBTkQgY2hhbm5lbD1cIkZPWFwiIn0seyJjb2xvciI6IiM3NkI3QjIiLCJ0ZXh0IjoidGV4dD0gXCJ3b21lbiBjYW5kaWRhdGVzXCIgQU5EIGNoYW5uZWw9XCJNU05CQ1wiIn1dfQ


**use: "analyzer data by outlet_bauer et al_feb23.csv"
*making figure by outlet, Figure A1
*bauer et al feb 23

*1 cnn 2 fox 3 msnbc

use "H:\My Drive\Research\Bauer et al\analyzer data by outlet_bauer et al_feb23.csv"

drop v5 v6 v7 v8 v9 v10 v11 v12

gen time_date = date(time, "MDY")
format time_date %td
gen year= year(time_date)

save "H:\My Drive\Research\Bauer et al\analyzer data by outlet_bauer et al_feb23.dta", replace

sort channel time_date 
save "H:\My Drive\Research\Bauer et al\analyzer data by outlet_bauer et al_feb23.dta", replace
collapse (mean) value, by(channel year)
sort  channel year
graph twoway line value year, by(channel)
gen cnn_dur=value if channel==1
gen fox_dur=value if channel==2
gen msnbc_dur=value if channel==3
save "H:\My Drive\Research\Bauer et al\collapsed data_by outlet.dta"
collapse (mean) cnn_dur fox_dur msnbc_dur, by(year)
line cnn_dur fox_dur msnbc_dur year
**creates figure A1.

** use "H:\My Drive\Research\Bauer et al\analyzer data by outlet_bauer et al_feb23.csv"


**Study 1, Abortion study
**use study1abortion.dta


**Figure 2,left panel, Abortion Study, Table A5
ttest favor1 if collapsed_conditions==1|collapsed_conditions==2, by(collapsed_conditions)
ttest favor1 if collapsed_conditions==3|collapsed_conditions==4, by(collapsed_conditions)
ttest favor1 if collapsed_conditions==1|collapsed_conditions==4, by(collapsed_conditions)
ttest favor1 if collapsed_conditions==2|collapsed_conditions==3, by(collapsed_conditions)

**Figure 3,left panel, Abortion Study, Table A5
ttest vote1 if collapsed_conditions==1|collapsed_conditions==2, by(collapsed_conditions)
ttest vote1 if collapsed_conditions==3|collapsed_conditions==4, by(collapsed_conditions)
ttest vote1 if collapsed_conditions==1|collapsed_conditions==4, by(collapsed_conditions)
ttest vote1 if collapsed_conditions==2|collapsed_conditions==3, by(collapsed_conditions)


**Figure 4,left panel, Abortion Study, Table A7
ttest favor1 if collapsed_conditions==1&woman==1|collapsed_conditions==2&woman==1, by(collapsed_conditions)
ttest favor1 if collapsed_conditions==1&woman==0|collapsed_conditions==2&woman==0, by(collapsed_conditions)
ttest favor1 if collapsed_conditions==3&woman==1|collapsed_conditions==4&woman==1, by(collapsed_conditions)
ttest favor1 if collapsed_conditions==3&woman==0|collapsed_conditions==4&woman==0, by(collapsed_conditions)
ttest favor1 if collapsed_conditions==1&woman==1|collapsed_conditions==4&woman==1, by(collapsed_conditions)
ttest favor1 if collapsed_conditions==1&woman==0|collapsed_conditions==2&woman==0, by(collapsed_conditions)
ttest favor1 if collapsed_conditions==2&woman==1|collapsed_conditions==3&woman==1, by(collapsed_conditions)
ttest favor1 if collapsed_conditions==2&woman==0|collapsed_conditions==3&woman==0, by(collapsed_conditions)


ttest favor1 if collapsed_conditions==1, by(woman)
ttest favor1 if collapsed_conditions==2, by(woman)
ttest favor1 if collapsed_conditions==3, by(woman)
ttest favor1 if collapsed_conditions==4, by(woman)

**Figure 5, left panel, Abortion Study, Table A7
ttest vote1 if collapsed_conditions==1&woman==1|collapsed_conditions==2&woman==1, by(collapsed_conditions)
ttest vote1 if collapsed_conditions==1&woman==0|collapsed_conditions==2&woman==0, by(collapsed_conditions)
ttest vote1 if collapsed_conditions==3&woman==1|collapsed_conditions==4&woman==1, by(collapsed_conditions)
ttest vote1 if collapsed_conditions==3&woman==0|collapsed_conditions==4&woman==0, by(collapsed_conditions)
ttest vote1 if collapsed_conditions==1&woman==1|collapsed_conditions==4&woman==1, by(collapsed_conditions)


ttest vote1 if collapsed_conditions==1, by(woman)
ttest vote1 if collapsed_conditions==2, by(woman)
ttest vote1 if collapsed_conditions==3, by(woman)
ttest vote1 if collapsed_conditions==4, by(woman)

**Partisan Differences Tests, Abortion Study, Appendix 3, Table A6 

ttest favor1 if full_conditions==2|full_conditions==7, by(full_conditions)
ttest favor1 if full_conditions==3|full_conditions==8, by(full_conditions)
ttest favor1 if full_conditions==2|full_conditions==3, by(full_conditions)
ttest favor1 if full_conditions==7|full_conditions==8, by(full_conditions)
ttest favor1 if full_conditions==1|full_conditions==5, by(full_conditions)
ttest favor1 if full_conditions==4|full_conditions==6, by(full_conditions)
ttest favor1 if full_conditions==1|full_conditions==4, by(full_conditions)
ttest favor1 if full_conditions==5|full_conditions==6, by(full_conditions)

ttest vote1 if full_conditions==2|full_conditions==7, by(full_conditions)
ttest vote1 if full_conditions==3|full_conditions==8, by(full_conditions)
ttest vote1 if full_conditions==2|full_conditions==3, by(full_conditions)
ttest vote1 if full_conditions==7|full_conditions==8, by(full_conditions)
ttest vote1 if full_conditions==1|full_conditions==5, by(full_conditions)
ttest vote1 if full_conditions==4|full_conditions==6, by(full_conditions)
ttest vote1 if full_conditions==1|full_conditions==4, by(full_conditions)
ttest vote1 if full_conditions==5|full_conditions==6, by(full_conditions)

**Table A8
ttest favor1 if full_conditions==1&woman==1|full_conditions==2&woman==1, by(full_conditions)
ttest favor1 if full_conditions==5&woman==1|full_conditions==7&woman==1, by(full_conditions)
ttest favor1 if full_conditions==3&woman==1|full_conditions==4&woman==1, by(full_conditions)
ttest favor1 if full_conditions==6&woman==1|full_conditions==8&woman==1, by(full_conditions)
ttest favor1 if full_conditions==1&woman==1|full_conditions==5&woman==1, by(full_conditions)
ttest favor1 if full_conditions==2&woman==1|full_conditions==7&woman==1, by(full_conditions)
ttest favor1 if full_conditions==3&woman==1|full_conditions==8&woman==1, by(full_conditions)
ttest favor1 if full_conditions==4&woman==1|full_conditions==6&woman==1, by(full_conditions)

**Study 2, Equal Pay 
**use study2equalpay.dta

**Figure 2, right panel, Equal Pay Study, Table A9
ttest favorability1 if lsu336rand==1|lsu336rand==3, by(lsu336rand)
ttest favorability1 if lsu336rand==2|lsu336rand==4, by(lsu336rand)
ttest favorability1 if lsu336rand==1|lsu336rand==2, by(lsu336rand)
ttest favorability1 if lsu336rand==3|lsu336rand==4, by(lsu336rand)

**Figure 3,right panel, Equal Pay Study, Table A9
ttest vote1 if lsu336rand==1|lsu336rand==2, by(lsu336rand)
ttest vote1 if lsu336rand==3|lsu336rand==4, by(lsu336rand)
ttest vote1 if lsu336rand==1|lsu336rand==3, by(lsu336rand)
ttest vote1 if lsu336rand==2|lsu336rand==4, by(lsu336rand)

**Figure 4,right panel, Equal Pay Study, Table A11

ttest favorability1 if lsu336rand==1&female==1|lsu336rand==3&female==1, by(lsu336rand)
ttest favorability1 if lsu336rand==1&female==0|lsu336rand==3&female==0, by(lsu336rand)
ttest favorability1 if lsu336rand==2&female==1|lsu336rand==4&female==1, by(lsu336rand)
ttest favorability1 if lsu336rand==2&female==0|lsu336rand==4&female==0, by(lsu336rand)
ttest favorability1 if lsu336rand==3&female==1|lsu336rand==4&female==1, by(lsu336rand)
ttest favorability1 if lsu336rand==1&female==1|lsu336rand==2&female==1, by(lsu336rand)
ttest favorability1 if lsu336rand==3&female==0|lsu336rand==4&female==0, by(lsu336rand)
ttest favorability1 if lsu336rand==1&female==0|lsu336rand==2&female==0, by(lsu336rand)

ttest favorability1 if lsu336rand==1, by(female)
ttest favorability1 if lsu336rand==3, by(female)
ttest favorability1 if lsu336rand==2, by(female)
ttest favorability1 if lsu336rand==4, by(female)


**Figure 5, right panel, Equal Pay Study, Table A11
ttest vote1 if lsu336rand==1&female==1|lsu336rand==3&female==1, by(lsu336rand)
ttest vote1 if lsu336rand==1&female==0|lsu336rand==3&female==0, by(lsu336rand)
ttest vote1 if lsu336rand==2&female==1|lsu336rand==4&female==1, by(lsu336rand)
ttest vote1 if lsu336rand==2&female==0|lsu336rand==4&female==0, by(lsu336rand)
ttest vote1 if lsu336rand==3&female==1|lsu336rand==4&female==1, by(lsu336rand)
ttest vote1 if lsu336rand==1&female==1|lsu336rand==2&female==1, by(lsu336rand)

ttest vote1 if lsu336rand==1, by(female)
ttest vote1 if lsu336rand==3, by(female)
ttest vote1 if lsu336rand==2, by(female)
ttest vote1 if lsu336rand==4, by(female)

**Partisan Differences Tests, Equal Pay Study, Appendix 3, Table A10

ttest favorability1 if lsu336rand==1&democrat_part==1|lsu336rand==2&democrat_part==1, by(lsu336rand)
ttest favorability1 if lsu336rand==1&democrat_part==0|lsu336rand==2&democrat_part==0, by(lsu336rand)
ttest favorability1 if lsu336rand==1, by(democrat_part)
ttest favorability1 if lsu336rand==2, by(democrat_part)

ttest favorability1 if lsu336rand==3&democrat_part==1|lsu336rand==4&democrat_part==1, by(lsu336rand)
ttest favorability1 if lsu336rand==3&democrat_part==0|lsu336rand==4&democrat_part==0, by(lsu336rand)
ttest favorability1 if lsu336rand==3, by(democrat_part)
ttest favorability1 if lsu336rand==4, by(democrat_part)

ttest vote1 if lsu336rand==1&democrat_part==1|lsu336rand==2&democrat_part==1, by(lsu336rand)
ttest vote1 if lsu336rand==1&democrat_part==0|lsu336rand==2&democrat_part==0, by(lsu336rand)
ttest vote1 if lsu336rand==1, by(democrat_part)
ttest vote1 if lsu336rand==2, by(democrat_part)

ttest vote1 if lsu336rand==3&democrat_part==1|lsu336rand==4&democrat_part==1, by(lsu336rand)
ttest vote1 if lsu336rand==3&democrat_part==0|lsu336rand==4&democrat_part==0, by(lsu336rand)
ttest vote1 if lsu336rand==3, by(democrat_part)
ttest vote1 if lsu336rand==4, by(democrat_part)

**Table A12
ttest favorability1 if lsu336rand==2&democrat_part==1&female==1|lsu336rand==4&democrat_part==1&female==1, by(lsu336rand)
ttest favorability1 if lsu336rand==1&democrat_part==0&female==1|lsu336rand==3&democrat_part==0&female==1, by(lsu336rand)
ttest favorability1 if lsu336rand==2&democrat_part==0&female==1|lsu336rand==4&democrat_part==0&female==1, by(lsu336rand)

ttest favorability1 if lsu336rand==1&female==1, by(democrat_part)
ttest favorability1 if lsu336rand==3&female==1, by(democrat_part)
ttest favorability1 if lsu336rand==2&female==1, by(democrat_part)
ttest favorability1 if lsu336rand==4&female==1, by(democrat_part)

ttest vote1 if lsu336rand==1&democrat_part==1&female==1|lsu336rand==3&democrat_part==1&female==1, by(lsu336rand)
ttest vote1 if lsu336rand==2&democrat_part==1&female==1|lsu336rand==4&democrat_part==1&female==1, by(lsu336rand)
ttest vote1 if lsu336rand==1&democrat_part==0&female==1|lsu336rand==3&democrat_part==0&female==1, by(lsu336rand)
ttest vote1 if lsu336rand==2&democrat_part==0&female==1|lsu336rand==4&democrat_part==0&female==1, by(lsu336rand)

ttest vote1 if lsu336rand==1&female==1, by(democrat_part)
ttest vote1 if lsu336rand==3&female==1, by(democrat_part)
ttest vote1 if lsu336rand==2&female==1, by(democrat_part)
ttest vote1 if lsu336rand==4&female==1, by(democrat_part)






